﻿using System.Collections.Generic;
using DAO;
using DTO;

namespace BUS
{
    public class EmailDangKyNhanTinRaoVatBUS
    {
        public static List<EmailDangKyNhanTinRaoVatDTO> getAll()
        {
            return EmailDangKyNhanTinRaoVatDAO.getAll();
        }

        public static EmailDangKyNhanTinRaoVatDTO getAlongCode(int maEmail)
        {
            return EmailDangKyNhanTinRaoVatDAO.getAlongCode(maEmail);
        }

        public static List<EmailDangKyNhanTinRaoVatDTO> LayDSTheoMaDanhMucCon(int madanhmuccon)
        {
            return EmailDangKyNhanTinRaoVatDAO.LayDSTheoMaDanhMucCon(madanhmuccon);
        }

        public static bool KiemTraDaDangKyTatCa(string email)
        {
            return EmailDangKyNhanTinRaoVatDAO.KiemTraDaDangKyTatCa(email);
        }

        public static bool KiemTraDangKyRoi(string email, int madanhmuccon)
        {
            return EmailDangKyNhanTinRaoVatDAO.KiemTraDangKyRoi(email, madanhmuccon);
        }

        public static void Insert(EmailDangKyNhanTinRaoVatDTO _insert)
        {
            EmailDangKyNhanTinRaoVatDAO.Insert(_insert);
        }

        public static void Delete(int maEmail)
        {
            EmailDangKyNhanTinRaoVatDAO.Delete(maEmail);
        }

        public static void Update(EmailDangKyNhanTinRaoVatDTO dto)
        {
            EmailDangKyNhanTinRaoVatDAO.Update(dto);
        }
    }
}
